package main

import (
	"fmt"
	"math"
	"runtime"
)

func main() {
	fmt.Println("Go runs on ")
	switch os := runtime.GOOS; os {
	case "darwin":
		fmt.Println("OS X")
	case "linux":
		fmt.Println("Lniux")
	default:
		fmt.Println(os)
	}
	a := 2 //
	b := a << 1
	c := a >> 1
	var d uint64 = 1<<64 - 1
	var f float64 = math.Pow(2, 64) - 1
	fmt.Printf("二进制为：%b 十进制为：%d\n", a, a)
	fmt.Printf("二进制为：%b 十进制为：%d\n", b, b)
	fmt.Printf("二进制为：%b 十进制为：%d\n", c, c)
	fmt.Printf("二进制为：%b 十进制为：%d\n", d, d)
	fmt.Printf("二进制为：%b 十进制为：%f\n", f, f)
}
